Optimal. Leaf size=81 \[ -\frac {(3 b d e-3 b c f-2 a d f) x}{3 f^2}+\frac {d x \left (a+b x^2\right )}{3 f}+\frac {(b e-a f) (d e-c f) \tan ^{-1}\left (\frac {\sqrt {f} x}{\sqrt {e}}\right )}{\sqrt {e} f^{5/2}} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.05, antiderivative size = 81, normalized size of antiderivative = 1.00, number of steps
used = 3, number of rules used = 3, integrand size = 24, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.125, Rules used = {542, 396, 211}
\begin {gather*} \frac {(b e-a f) \text {ArcTan}\left (\frac {\sqrt {f} x}{\sqrt {e}}\right ) (d e-c f)}{\sqrt {e} f^{5/2}}-\frac {x (-2 a d f-3 b c f+3 b d e)}{3 f^2}+\frac {d x \left (a+b x^2\right )}{3 f} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 211
Rule 396
Rule 542
Rubi steps
\begin {align*} \int \frac {\left (a+b x^2\right ) \left (c+d x^2\right )}{e+f x^2} \, dx &=\frac {d x \left (a+b x^2\right )}{3 f}+\frac {\int \frac {-a (d e-3 c f)-(3 b d e-3 b c f-2 a d f) x^2}{e+f x^2} \, dx}{3 f}\\ &=-\frac {(3 b d e-3 b c f-2 a d f) x}{3 f^2}+\frac {d x \left (a+b x^2\right )}{3 f}+\frac {((b e-a f) (d e-c f)) \int \frac {1}{e+f x^2} \, dx}{f^2}\\ &=-\frac {(3 b d e-3 b c f-2 a d f) x}{3 f^2}+\frac {d x \left (a+b x^2\right )}{3 f}+\frac {(b e-a f) (d e-c f) \tan ^{-1}\left (\frac {\sqrt {f} x}{\sqrt {e}}\right )}{\sqrt {e} f^{5/2}}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.04, size = 72, normalized size = 0.89 \begin {gather*} \frac {(-b d e+b c f+a d f) x}{f^2}+\frac {b d x^3}{3 f}+\frac {(b e-a f) (d e-c f) \tan ^{-1}\left (\frac {\sqrt {f} x}{\sqrt {e}}\right )}{\sqrt {e} f^{5/2}} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A]
time = 0.14, size = 74, normalized size = 0.91
method | result | size |
default | \(\frac {\frac {1}{3} b d \,x^{3} f +a d f x +b c f x -b d e x}{f^{2}}+\frac {\left (a c \,f^{2}-a d e f -b c e f +b d \,e^{2}\right ) \arctan \left (\frac {f x}{\sqrt {f e}}\right )}{f^{2} \sqrt {f e}}\) | \(74\) |
risch | \(\frac {b d \,x^{3}}{3 f}+\frac {a d x}{f}+\frac {b c x}{f}-\frac {b d e x}{f^{2}}-\frac {\ln \left (f x +\sqrt {-f e}\right ) a c}{2 \sqrt {-f e}}+\frac {\ln \left (f x +\sqrt {-f e}\right ) a d e}{2 f \sqrt {-f e}}+\frac {\ln \left (f x +\sqrt {-f e}\right ) b c e}{2 f \sqrt {-f e}}-\frac {\ln \left (f x +\sqrt {-f e}\right ) b d \,e^{2}}{2 f^{2} \sqrt {-f e}}+\frac {\ln \left (-f x +\sqrt {-f e}\right ) a c}{2 \sqrt {-f e}}-\frac {\ln \left (-f x +\sqrt {-f e}\right ) a d e}{2 f \sqrt {-f e}}-\frac {\ln \left (-f x +\sqrt {-f e}\right ) b c e}{2 f \sqrt {-f e}}+\frac {\ln \left (-f x +\sqrt {-f e}\right ) b d \,e^{2}}{2 f^{2} \sqrt {-f e}}\) | \(235\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A]
time = 0.52, size = 73, normalized size = 0.90 \begin {gather*} \frac {{\left (a c f^{2} + b d e^{2} - {\left (b c e + a d e\right )} f\right )} \arctan \left (\sqrt {f} x e^{\left (-\frac {1}{2}\right )}\right ) e^{\left (-\frac {1}{2}\right )}}{f^{\frac {5}{2}}} + \frac {b d f x^{3} - 3 \, {\left (b d e - {\left (b c + a d\right )} f\right )} x}{3 \, f^{2}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 0.95, size = 191, normalized size = 2.36 \begin {gather*} \left [-\frac {{\left (6 \, b d f x e^{2} + 3 \, {\left (a c f^{2} + b d e^{2} - {\left (b c + a d\right )} f e\right )} \sqrt {-f e} \log \left (\frac {f x^{2} - 2 \, \sqrt {-f e} x - e}{f x^{2} + e}\right ) - 2 \, {\left (b d f^{2} x^{3} + 3 \, {\left (b c + a d\right )} f^{2} x\right )} e\right )} e^{\left (-1\right )}}{6 \, f^{3}}, -\frac {{\left (3 \, b d f x e^{2} - 3 \, {\left (a c f^{2} + b d e^{2} - {\left (b c + a d\right )} f e\right )} \sqrt {f} \arctan \left (\sqrt {f} x e^{\left (-\frac {1}{2}\right )}\right ) e^{\frac {1}{2}} - {\left (b d f^{2} x^{3} + 3 \, {\left (b c + a d\right )} f^{2} x\right )} e\right )} e^{\left (-1\right )}}{3 \, f^{3}}\right ] \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [B] Leaf count of result is larger than twice the leaf count of optimal. 206 vs.
\(2 (73) = 146\).
time = 0.39, size = 206, normalized size = 2.54 \begin {gather*} \frac {b d x^{3}}{3 f} + x \left (\frac {a d}{f} + \frac {b c}{f} - \frac {b d e}{f^{2}}\right ) - \frac {\sqrt {- \frac {1}{e f^{5}}} \left (a f - b e\right ) \left (c f - d e\right ) \log {\left (- \frac {e f^{2} \sqrt {- \frac {1}{e f^{5}}} \left (a f - b e\right ) \left (c f - d e\right )}{a c f^{2} - a d e f - b c e f + b d e^{2}} + x \right )}}{2} + \frac {\sqrt {- \frac {1}{e f^{5}}} \left (a f - b e\right ) \left (c f - d e\right ) \log {\left (\frac {e f^{2} \sqrt {- \frac {1}{e f^{5}}} \left (a f - b e\right ) \left (c f - d e\right )}{a c f^{2} - a d e f - b c e f + b d e^{2}} + x \right )}}{2} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A]
time = 1.18, size = 80, normalized size = 0.99 \begin {gather*} \frac {{\left (a c f^{2} - b c f e - a d f e + b d e^{2}\right )} \arctan \left (\sqrt {f} x e^{\left (-\frac {1}{2}\right )}\right ) e^{\left (-\frac {1}{2}\right )}}{f^{\frac {5}{2}}} + \frac {b d f^{2} x^{3} + 3 \, b c f^{2} x + 3 \, a d f^{2} x - 3 \, b d f x e}{3 \, f^{3}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [B]
time = 0.11, size = 108, normalized size = 1.33 \begin {gather*} x\,\left (\frac {a\,d+b\,c}{f}-\frac {b\,d\,e}{f^2}\right )+\frac {b\,d\,x^3}{3\,f}+\frac {\mathrm {atan}\left (\frac {\sqrt {f}\,x\,\left (a\,f-b\,e\right )\,\left (c\,f-d\,e\right )}{\sqrt {e}\,\left (a\,c\,f^2+b\,d\,e^2-a\,d\,e\,f-b\,c\,e\,f\right )}\right )\,\left (a\,f-b\,e\right )\,\left (c\,f-d\,e\right )}{\sqrt {e}\,f^{5/2}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________